﻿namespace Taobao.ObjectModel.Request
{
    public class RequestOption
    {
        private const string DefaultOrderBy = "delist_time:asc";
        private const string DefaultFields = "num_iid,title,delist_time,has_showcase";
        private const int DefaultPageSize = 40;

        private static RequestOption defaultOption;

        public string Fields { get; set; }
        public string OrderBy { get; set; }
        public int PageSize { get; set; }

        public static RequestOption Default
        {
            get
            {
                if(null == defaultOption)
                {
                    defaultOption = new RequestOption {Fields = DefaultFields, OrderBy = DefaultOrderBy, PageSize = DefaultPageSize};
                }
                return defaultOption;
            }
        }
    }
}
